<!DOCTYPE html>
<html lang="en">
<html>
<head>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<title>Document</title>
	<meta charset="utf-8">
	<title>Layui</title>
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	<link rel="stylesheet" href="/assets/lib/layui/css/layui.css">
	<!-- 注意：如果你直接复制所有代码到本地，上述css路径需要改成你本地的 -->
	<link rel="stylesheet" href="/assets/lib/cropper/cropper.css" />
	<link rel="stylesheet" href="/artice/artice_css/art_pub.css">
</head>

<body>
	<script src="/assets/lib/layui/layui.all.js"></script>
	<!-- <fieldset >
		<legend>表单集合演示1111111</legend>
	</fieldset> -->

	<div class="layui-card">
		<div class="layui-card-header" style="padding:5px;">
			<div class="layui-row">
				<div class="layui-col-md5" style="height: 38px;
    line-height: 38px;">写文章
				</div>
				<!-- <div class="layui-col-md1 layui-col-md-offset6 " style="text-align: center;">
					<button type="button" class="layui-btn add">添加</button>
				</div> -->
			</div>


		</div>
		<div class="layui-card-body">
			<form class="layui-form" action="" id="pubform">
				<div class="layui-form-item">
					<label class="layui-form-label">文章标题</label>
					<div class="layui-input-block">
						<input type="text" name="title" lay-verify="title" autocomplete="off" placeholder="请输入标题"
							class="layui-input">
					</div>
				</div>

				<div class="layui-form-item">
					<label class="layui-form-label">文章类别</label>
					<div class="layui-input-block">
						<select name="cate_id" lay-filter="aihao" id="leibie">
						</select>
                         <!-- 模板 -->
            <script type="text/html" id="opt">
                <option value="">请选择文章类别</option>
                {{each data}}
                <option value="{{$value.Id}}">{{$value.name}}</option>
                {{/each}}
              </script>
              <!-- 模板 -->
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label">文章内容</label>
					<div class="layui-input-block">
						<textarea placeholder="请输入内容" class="layui-textarea" name="content"></textarea>
					</div>
				</div>

				<div class="layui-form-item layui-form-text">
					<label class="layui-form-label">文章封面</label>
					<div class="layui-input-block" style="display: flex;">
						<div class="row1">
							<!-- 图片裁剪区域 -->
							<div class="cropper-box">
								<!-- 这个 img 标签很重要，将来会把它初始化为裁剪区域 -->
								<img style="width:200px;height:200px;" id="image" src="/assets/images/sample.jpg" />
							</div>
							<!-- 图片的预览区域 -->
							<div class="preview-box">
								<div>
									<!-- 宽高为 100px 的预览区域 -->
									<div class="img-preview w100"></div>
									<input type="file" style="display: none;" name="" id="uploadFile">
									<button style="width:100px;" type="button" class="layui-btn upload layui-btn-sm">上传</button>
								</div>

							</div>
						</div>

					</div>
				</div>
				<div class="layui-form-item">
					<div class="layui-input-block">
						<button type="submit" class="layui-btn" lay-submit="" lay-filter="demo1" id="pub">发布</button>
						<button type="reset" class="layui-btn layui-btn-primary caogao">存为草稿</button>
					</div>
				</div>
			</form>
		</div>


		<script src="/assets/lib/layui/layui.all.js"></script>
		<script src="/assets/lib/jquery.js"></script>
		<script src="/assets/lib/cropper/Cropper.js"></script>
		<script src="/assets/lib/cropper/jquery-cropper.js"></script>

		<script src="/assets/lib/template-web.js"></script>
		<script src="/assets/js/baseAPI.js"></script>
		<script src="/artice/artice_js/art_pub.js"></script>
</body>

</html>